package tech.shupi.babytapmobile.view

import com.facebook.react.uimanager.SimpleViewManager
import com.facebook.react.uimanager.ThemedReactContext
import com.facebook.react.uimanager.annotations.ReactProp

class RnSecureImageViewManager : SimpleViewManager<RnSecureImageView>() {
    override fun getName(): String = "RnSecureImageView"

    override fun createViewInstance(reactContext: ThemedReactContext): RnSecureImageView {
        return RnSecureImageView(reactContext)
    }

    @ReactProp(name = "source")
    fun setSource(view: RnSecureImageView, source: com.facebook.react.bridge.ReadableMap?) {
        val uri = source?.getString("uri")
        view.setImageUrl(uri)
    }
} 